<?xml version="1.0" encoding ="UTF-8"?>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 1.0 Transitional//EN" "http://www.w3.org/TR/htmL1/DTD/xhtml1-transitional.dtd">

<%@ page contentType="text/html; charset=utf-8" %>
<%@ taglib prefix="s" uri="/struts-tags" %>

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title></title>
<link rel="stylesheet" type="text/css" href="/inc/css/common.css">
<script type="text/javascript" src="/inc/js/common.js"></script>
<s:head theme="ajax"/>
<SCRIPT type="text/javascript">
function ln_Close(code, code_nm){
	var flag=document.form.flag.value;
	
	if(flag == "a"){
		opener.document.add_fm.yesan_code.value=code;
		opener.document.add_fm.yesan_nm.value=code_nm;
		window.close();	
	}
	if(flag == "regFAslip"){

		opener.document.form1.account_code.value=code;
		opener.document.form1.account_nm.value=code_nm;
		
		var onyeondo = opener.document.form1.nyeondo;
		var ogubun_hwoigye = opener.document.form1.gubun_hwoigye;
		var obuseo_baleui = opener.document.form1.buseo_baleui;
		var param = "nyeondo="+onyeondo.value+"&gubun_hwoigye="+ogubun_hwoigye.options[ogubun_hwoigye.selectedIndex].value
		+"&buseo_baleui="+obuseo_baleui.options[obuseo_baleui.selectedIndex].value;
		
		location.href="commonAction.action?account_code ="+code+"&flag=check_account_code_Slip&"+param;
 		opener.focus();

		//window.close();
	}
	if(flag == "modifySlip"){

		opener.document.form1.account_code.value=code;
		opener.document.form1.account_nm.value=code_nm;
		
		var onyeondo = opener.document.form1.nyeondo;
		var ogubun_hwoigye = opener.document.form1.gubun_hwoigye;
		var obuseo_baleui = opener.document.form1.buseo_baleui;
		var param = "nyeondo="+onyeondo.value+"&gubun_hwoigye="+ogubun_hwoigye.value
		+"&buseo_baleui="+obuseo_baleui.value;
		
		location.href="commonAction.action?account_code ="+code+"&flag=check_account_code_Slip&"+param;
 		opener.focus();

		//window.close();
	}
	
}
</SCRIPT>
</head>
<body>
</body>
<div id="popup_550se_top"></div>
	<div id="popup_150se_bg">
	</div>
	<s:form theme="simple" name="form" id="form">
	<s:hidden name="flag"/>
	<table class="pop550se_Tbl">
		
		<tr>
		<th>계정과목명</th>
		<td><s:textfield name="search_codeName"/> </td>
		<td><s:submit type="image" src="/images/btn_search02.gif" action="gjeong_search"/></td>
		</tr>
			
	</table>
	<table class="popitem_bottom_tbl">
	<tr>
		<th>계정코드</th>
		<th>계정명</th>
	</tr>
	
		<s:iterator value="list" id="id">
		<tr>
			<td>
			<s:property value="yesan_code"/></td>
			<td>
			<a href="javascript:ln_Close('<s:property value="yesan_code"/>','<s:property value="yesan_nm"/>')" class="blue">
			<s:property value="yesan_nm"/>
			</a>
			</td>
		</tr>	
		</s:iterator>
	</table>
	</s:form>
	</div>
	<div id="popup_550se_bottom">
	<input type="image" src="/images/pop_btn_close.gif" onclick="window.close()" />
	</div>
	
</html>
